{#
 This Source Code Form is subject to the terms of the Mozilla Public
 License, v. 2.0. If a copy of the MPL was not distributed with this
 file, You can obtain one at https://mozilla.org/MPL/2.0/.
#}

{% if LANG == 'fr' %}
  {% set cta_text = "Faire un don  ♥" %}
{% elif LANG == 'de' %}
  {% set cta_text = "Spenden ♥" %}
{% elif LANG == 'es-ES' %}
  {% set cta_text = "Donar ♥" %}
{% elif LANG == 'pt-BR' %}
  {% set cta_text = "Doe agora ♥" %}
{% elif LANG == 'pl' %}
  {% set cta_text = "Wpłać datek ♥" %}
{% elif LANG == 'it' %}
  {% set cta_text = "Dona ♥" %}
{% else %}
  {% set cta_text = "Donate ♥" %}
{% endif %}

{% set cta_link = "https://mozillafoundation.org/?form=eoy25-moco-banner" %}

{% if LANG == 'fr' %}
  {% set banner_content = "Faites un don à la Fondation Mozilla avant le 31 décembre" %}
{% elif LANG == 'de' %}
  {% set banner_content = "Spenden Sie bis zum 31. Dezember an die Mozilla Foundation" %}
{% elif LANG == 'es-ES' %}
  {% set banner_content = "Dona a la Fundación Mozilla antes del 31 de diciembre" %}
{% elif LANG == 'pt-BR' %}
  {% set banner_content = "Doe para a Fundação Mozilla até 31 de dezembro" %}
{% elif LANG == 'pl' %}
  {% set banner_content = "Przekaż datek Fundacji Mozilla do 31 grudnia" %}
{% elif LANG == 'it' %}
  {% set banner_content = "Dona a Mozilla Foundation entro il 31 dicembre" %}
{% else %}
  {% set banner_content = "Donate to Mozilla Foundation by December 31" %}
{% endif %}

{% if switch('show-pencil-banner') and not hide_pencil_banner and is_homepage and (LANG  in ['fr', 'de', 'es-ES', 'pt-BR', 'pl', 'it'] or LANG.startswith('en-')) %}
  {# Exclude banners from search result snippets using `data-nosnippet` (issue 8739) #}
  <aside class="m24-pencil-banner" aria-label="{{ ftl('ui-promo-label') }}" data-nosnippet="true">
    <div class="m24-pencil-banner-copy">
      <p>{{banner_content}} – <strong><a href={{cta_link}} data-cta-text="Donate" data-cta-position="banner">{{cta_text}}</a></strong></p>
    </div>
    <button class="m24-pencil-banner-close" type="button">{{ ftl('ui-close') }}</button>
  </aside>
{% endif %}
